Skip to content

Implement equals and hashCode in ImmutablePublicKeyCredentialUserEntity#18883

Open
aspan wants to merge 1 commit intospring-projects:mainfrom
aspan:gh-18882
Open

Implement equals and hashCode in ImmutablePublicKeyCredentialUserEntity#18883
aspan wants to merge 1 commit intospring-projects:mainfrom
aspan:gh-18882

Conversation

@aspan
Copy link
Contributor

@aspan aspan commented Mar 12, 2026

No description provided.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Mar 12, 2026
@jzheaux jzheaux self-assigned this Mar 21, 2026
@jzheaux jzheaux changed the title Implement equals and hashCode in ImmutablePublicKeyCredentialUserEntity closes gh-18882 Implement equals and hashCode in ImmutablePublicKeyCredentialUserEntity Mar 21, 2026
@jzheaux jzheaux added type: enhancement A general enhancement in: oauth2 An issue in OAuth2 modules (oauth2-core, oauth2-client, oauth2-resource-server, oauth2-jose) and removed status: waiting-for-triage An issue we've not yet triaged labels Mar 21, 2026
@jzheaux jzheaux added this to the 7.1.0-RC1 milestone Mar 21, 2026
Copy link
Contributor

@jzheaux jzheaux left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR, @aspan! I've left some feedback inline.

if (!(obj instanceof ImmutablePublicKeyCredentialUserEntity that)) {
return false;
}
return Objects.equals(getName(), that.getName()) && Objects.equals(getId(), that.getId());
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will you please use this.name/that.name and this.id/that.id? The reason is so that this class doesn't get surprised with overridden implementations, should this class ever become non-final.

@jzheaux jzheaux added the status: waiting-for-feedback We need additional information before we can continue label Mar 21, 2026
Signed-off-by: Andreas Asplund <andreas@asplund.biz>
@aspan
Copy link
Contributor Author

aspan commented Mar 21, 2026

Hi Thanks for the feedback. I've made the requested changes.

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Mar 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

in: oauth2 An issue in OAuth2 modules (oauth2-core, oauth2-client, oauth2-resource-server, oauth2-jose) status: feedback-provided Feedback has been provided type: enhancement A general enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants